package com.qf.interfacedemo;

public class SwimUtils {

    public static void main(String[] args) {
        Dog dog = new Dog();
        trainSwim(dog);
//        Cat cat = new Cat();
//        trainSwim(cat);
    }

    public static void trainSwim(Swimable swimable){
        for (int i = 0; i < 3; i++) {
            swimable.swim();
        }
    }

}
